package com.atguigu.daedlock;

public class DeadLock {
    public static void main(String[] args) {
        Lock01 lock01 = new Lock01();
        Lock02 lock02 = new Lock02();
        new Thread(()->{
            lock01.lock();
            lock02.lock();
        }).start();

        new Thread(()->{
            lock02.lock();
            lock01.lock();
        }).start();

    }
}
